import uvicorn
from server import app, AppConfig


if __name__ == "__main__":
    # 检查是否在主进程中运行
    uvicorn.run(
        app="app:app",
        host=AppConfig.app_host,
        port=AppConfig.app_port,
        root_path=AppConfig.app_root_path,
        reload=AppConfig.app_reload,
        limit_concurrency=100,
        backlog=1000,
        loop="asyncio",
    )
